import java.util.*;

public class Test2 {

    public static void main(String[] args) {

        Scanner in = new Scanner(System.in);
        double[] shooting = new double[21];
        shooting[1] = 0;
        shooting[2] = 1;
        for(int i = 3; i <= 20; i++){
            shooting[i] = (i-1)*(shooting[i-1] + shooting[i-2]);
        }
        while (in.hasNextInt()) {
            int people = in.nextInt();
            long all = 1;
            for (int i = 1; i <= people; i++) {
                all *= i;
            }
            System.out.printf("%.2f",(shooting[people]/all)*100);
            System.out.println("%");
        }
    }

    public static void main12(String[] args) {
        Scanner in = new Scanner(System.in);
        while (in.hasNextLine()) {
            String list = in.nextLine();
            String person = in.nextLine();
            // 在该位置之前有几个"
            int[] splitName = new int[list.length()];
            if(list.charAt(0) == '\"'){
                splitName[0] = 1;
            }
            for(int i = 1; i < list.length(); i++){
                if(list.charAt(i) == '\"'){
                    splitName[i] = splitName[i-1]+1;
                }else{
                    splitName[i] = splitName[i-1];
                }
            }

            if(list.contains(person)){
                int start = list.indexOf(person);
                int end = start + person.length();

                if(splitName[start] % 2 != 0){
                    if (start > 0 && end < list.length()
                            && list.charAt(start-1) == '\"' && list.charAt(end) == '\"'){
                        System.out.println("Ignore");
                    }else {
                        System.out.println("Important!");
                    }
                }else {
                    if (!person.contains(",")){
                        System.out.println("Ignore");
                    }else{
                        System.out.println("Important!");
                    }
                }
            }else {
                System.out.println("Important!");
            }
        }
    }

    public static void main233(String[] args) {

        Scanner in = new Scanner(System.in);
        while (in.hasNextInt()) {
            int people = in.nextInt();
            in.nextLine();
            StringBuilder string = new StringBuilder();
            for(int i = 0; i < people; i++){
                String person = in.nextLine();
                if(person.contains(" ") || person.contains(",")){
                    if(string.length() != 0){
                        string.append(", ");
                    }
                    string.append("\"");
                    string.append(person);
                    string.append("\"");
                }else {
                    if(string.length() != 0){
                        string.append(", ");
                    }
                    string.append(person);
                }
            }
            System.out.println(string);
        }
    }


    public static void main3(String[] args){
        Scanner scanner = new Scanner(System.in);
        int[] bread = new int[81];
        bread[1] = 1;
        bread[2] = 1;
        // 初始化斐波那契数组
        for(int i = 3; i <= 80; i++){
            bread[i] = bread[i-1] + bread[i-2];
        }
        while(scanner.hasNextInt()){
            int from = scanner.nextInt();
            int to = scanner.nextInt();
            long ret = 0;
            for(int i = from; i <= to; i++){
                ret += bread[i];
            }
            System.out.println(ret);
        }
    }

    static int[] fib = new int[100001];
    public static void main13(String[] args) {
        fib[1] = 1;
        fib[2] = 2;
        for(int i = 3; i <= 100000; i++){
            fib[i] = (fib[i-1] + fib[i-2]) % 1000000;
        }
        Scanner in = new Scanner(System.in);
        while (in.hasNext()) {
            int n = in.nextInt();
            int ret = fib[n];
            if(ret <= 29){
                System.out.println(ret);
            }else {
                if(ret < 100000){
                    int count = 0;
                    int num = ret;
                    while(num > 0){
                        num /= 10;
                        count++;
                    }
                    while(6 - count > 0){
                        System.out.print(0);
                        count--;
                    }
                }
                System.out.println(ret);
            }
        }
    }

    public static void main33(String[] args){
        Scanner scanner = new Scanner(System.in);

        while(scanner.hasNextInt()){
            int year = scanner.nextInt();
            System.out.println(year+"-01-01");// 元旦
            // 得到该年的第一天是星期几
            int firstDay = WeekDay(year);
            int day = 1;
            // 1月第三个星期一
            if(firstDay == 1){
                day += 14;
            }else if(firstDay > 1){
                day += (7 - firstDay + 1) + 14;
            }else {
                day += (1 - firstDay) + 14;
            }
            System.out.println(year+"-01-"+ day);
            // 2月第三个星期一
            firstDay = (firstDay + 31) % 7;// 二月第一天星期几
            day = 1;
            if(firstDay == 1){
                day += 14;
            }else if(firstDay > 1){
                day += (7 - firstDay + 1) + 14;
            }else {
                day += (1 - firstDay) + 14;
            }
            System.out.println(year+"-02-"+day);
            // 5月最后一个星期一
            firstDay = (firstDay + 28 + 31 + 30) % 7;
            if(isRun(year)){
                firstDay = (firstDay+1) % 7;
            }
            day = 1;
            if(firstDay > 1){
                day += 7 - firstDay + 1;
            }else if(firstDay < 1){
                day += 1 - firstDay;
            }// 找到第一个星期一
            while(day + 7 <= 31){
                day += 7;
            }
            System.out.println(year+"-05-" + day);
            // 7 - 4
            System.out.println(year+"-07-04");
            // 9月第一个星期一
            day = 1;
            firstDay = (firstDay + 31 + 30 + 31 + 31) % 7;
            if(firstDay > 1){
                day += 7 - firstDay + 1;
            }else if(firstDay < 1){
                day += 1 - firstDay;
            }
            System.out.println(year+"-09-0"+day);
            // 11月第四个星期四
            day = 1;
            firstDay = (firstDay + 30 + 31) % 7;
            if(firstDay > 4){
                day += 7 - firstDay + 4;
            }else if(firstDay < 4){
                day += 4 - firstDay;
            }
            day += 21;
            System.out.println(year+"-11-"+day);
            // 12 -25
            System.out.println(year+"-12-25");
        }
    }
    public static int WeekDay(int year){
        int beginWeek = 6;// 2000年1月1日  星期六
        int beginYear = 2000;
        int days = 0;
        while(beginYear < year){
            if(isRun(beginYear)){
                days += 366;
            }else {
                days += 365;
            }
            beginYear++;
        }
        return (beginWeek + days) % 7;
    }
    public static boolean isRun(int year){
        if(year % 400 == 0 || year % 4 == 0 && year % 100 != 0){
            return true;
        }
        return false;
    }


    static int count;
    public static void main9(String[] args) {
        Scanner in = new Scanner(System.in);
        while (in.hasNext()) {
            int n = in.nextInt();
            int[] nums = new int[n];
            for(int i = 0; i < n; i++){
                nums[i] = in.nextInt();
            }
            Arrays.sort(nums);
            back(nums,0,0,1);
            System.out.println(count);
        }
    }
    public static void back(int[] nums,int start,int sum,int roduct){
        if (sum > roduct){
            count++;
        }
        for(int i = start; i < nums.length; i++){
            if (i > start && nums[i] == nums[i-1]) continue;
            if(sum != 0 && sum+nums[i] < roduct*nums[i]) continue;
            back(nums,i+1,sum+nums[i],roduct*nums[i]);
        }
    }




//    public static int[] months = {31,28,31,30,31,30,31,31,30,31,30};
//    public static void main3(String[] args){
//        Scanner scanner = new Scanner(System.in);
//        while(scanner.hasNext()){
//            String yearString = scanner.next();
//            String monthString = scanner.next();
//            String dayString = scanner.next();
//
//            int year = Integer.parseInt(yearString);
//            int month = Integer.parseInt(monthString);
//            int day = Integer.parseInt(dayString);
//
//            int ret = 0;
//            for(int i = 0; i < month - 1; i++){
//                ret += months[i];
//            }
//            if(isRun((year))){
//                ret++;
//            }
//            System.out.print(ret + day);
//        }
//    }
//    public static boolean isRun(int year){
//        if(year % 400 == 0 || year % 4 == 0 && year % 100 != 0){
//            return true;
//        }
//        return false;
//    }


    public static void main2(String[] args) {
        char[][]  board = new char[9][9];
        for (char[] chars : board) {
            Arrays.fill(chars,'.');
        }
        board[0][0] = '5';
        board[0][1] = '3';
        board[0][4] = '7';
        board[1][0] = '6';
        board[1][3] = '1';
        board[1][4] = '9';
        board[1][5] = '5';
        board[2][1] = '9';
        board[2][2] = '8';
        board[2][7] = '6';
        board[3][0] = '8';
        board[3][4] = '6';
        board[3][8] = '3';
        board[4][0] = '4';
        board[4][3] = '8';
        board[4][5] = '3';
        board[4][8] = '1';
        board[5][0] = '7';
        board[5][4] = '2';
        board[5][8] = '6';
        board[6][1] = '6';
        board[6][6] = '2';
        board[6][7] = '8';
        board[7][3] = '4';
        board[7][4] = '1';
        board[7][5] = '9';
        board[7][8] = '5';
        board[8][4] = '8';
        board[8][7] = '7';
        board[8][8] = '9';

        solveSudoku(board);
        for (int i = 0; i < board.length; i++) {
            for (int j = 0; j < board.length; j++) {
                System.out.print(board[i][j] + " ");
            }
            System.out.println();
        }
    }
    public static void solveSudoku(char[][] board) {
        back(0,0,board);
    }
    public static boolean back(int row,int line,char[][] board){
        if(row == 9){
            return true;
        }
        if(board[row][line] == '.'){
            for(char num = '1'; num <= '9'; num++){
                if(isValid(row,line,num,board)){
                    board[row][line] = num;
                    if(line < 8){
                        if (back(row,line+1,board)) return true;
                    }else {
                        if (back(row+1,0,board)) return true;
                    }
                    board[row][line] = '.';
                }
            }
        }else {
            if(line < 8){
                return back(row, line + 1, board);
            }else {
                return back(row + 1, 0, board);
            }
        }
        return false;
    }
    public static boolean isValid(int row,int line,char num,char[][] board){
        int len = board.length;
        // 数字 1-9 在每一行只能出现一次。
        for(int i = 0; i < len; i++){
            if(board[row][i] == num) return false;
        }
        // 数字 1-9 在每一列只能出现一次。
        for(int i = 0; i < len; i++){
            if(board[i][line] == num) return false;
        }
        // 数字 1-9 在每一个以粗实线分隔的 3x3 宫内只能出现一次。
        // 找到对应的 3x3宫格
        int startRow = row/3*3;
        int startLine = line/3*3;
        for(int i = startRow; i < startRow + 3; i++){
            for(int j = startLine; j < startLine + 3; j++){
                if(board[i][j] == num) return false;
            }
        }
        return true;
    }




    public static void main1(String[] args) {
        System.out.println(restoreIpAddresses("25525511135"));

        List<Integer> list = new ArrayList<>();
        Set<Integer> set = new HashSet<>();


        char i = '1';
        i++;
        System.out.println(i);
    }

    static List<String> ret = new ArrayList<>();
    static StringBuilder stringBuilder = new StringBuilder();
    public static List<String> restoreIpAddresses(String s) {
        if(s.length() > 12) return ret;
        back(s,0,0);
        return ret;
    }

    //  number : ip段数量
    public static void back(String s,int start,int number){
        if (start == s.length() && number == 4) {
            ret.add(stringBuilder.toString());
            return;
        }
        // 如果start等于s的长度但是ip段的数量不为4，或者ip段的数量为4但是start小于s的长度，则直接返回
        if (start == s.length() || number == 4) {
            return;
        }
        for(int end = start + 1; end <= s.length(); end++){
            String str = s.substring(start,end);
            if(isValid(str)){
                stringBuilder.append(str);
                if(number < 3){
                    stringBuilder.append(".");
                }
                back(s,end,number+1);
                stringBuilder.delete(start+number,end+number+1);
            }
        }
    }
    public static boolean isValid(String str){
        if(str.length() > 3) return false;
        if (str.charAt(0) == '0'){
            if(str.length() != 1) return false;
            else return true;
        }
        int num = Integer.parseInt(str);
        if(num > 0 && num <= 255){
            return true;
        }
        return false;
    }












//    List<String> ret = new ArrayList<>();
Map<String,Map<String,Integer>> map = new HashMap<>();

    public List<String> findItinerary(List<List<String>> tickets) {
        ret.add("JFK");
        for(List<String> ticket : tickets){
            Map<String,Integer> temp;
            if(map.containsKey(ticket.get(0))){
                temp = map.get(ticket.get(0));
                temp.put(ticket.get(1),temp.getOrDefault(ticket.get(1),0)+1);
            }else {
                temp = new TreeMap<>();
                temp.put(ticket.get(1),1);
            }
            map.put(ticket.get(0),temp);
        }
        back(tickets.size());
        return ret;
    }

    //                    航班数量
    public boolean back(int ticketNum){
        if(ret.size() == ticketNum + 1){
            return true;
        }
        String last = ret.get(ret.size()-1);
        if(map.containsKey(last)){
            for (Map.Entry<String, Integer> entry : map.get(last).entrySet()) {
                if (entry.getValue() > 0){
                    ret.add(entry.getKey());
                    entry.setValue(entry.getValue()-1);
                    if (back(ticketNum)) return true;
                    ret.remove(ret.size()-1);
                    entry.setValue(entry.getValue()+1);
                }
            }
        }

        return false;
    }
}
